<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="content-type" content="text/html" />
	<meta name="author" content="blog.anchen8.net" />
	<title>毕业生，你的选择</title>
    <link rel="stylesheet" type="text/css" href="../css/GetUrl.css" />
    <script type="text/javascript" src="/Bys-Website/js/jQuery1.82.js"></script>
    <script type="text/javascript">  
    function createMain(){
            var _scrollWidth=Math.max(document.body.scrollWidth,document.documentElement.scrollWidth);
            var _scrollHeight=Math.max(document.body.scrollHeight,document.documentElement.scrollHeight);
                document.getElementById("main").style.left=(_scrollWidth-950)/2+"px";
               // document.getElementById("m").style.height=_scrollHeight+"px";
        }
    $(document).ready(function() {
		$("#success").hide();
		$("#usernull").hide();
            
			$("#GetComfirmCode").click(function() {
				if($("#user").val()!=""){
				$("#usernull").hide();
				$("#success").hide();
				$("#GetComfirmCode").hide();
				$.post("SendCode", {
					username : $("#user").val()
				}, function(data) {
					$("#success").text(data);
					if($("#success").text()!=""){
						$("#GetComfirmCode").show();
					}else{
						location.href="Skip.jsp?p=sendcode";
					}
				});
				}else{
					$("#usernull").show();
				}
			});
           
		$("#success").ajaxSuccess(function() {
			$(this).show();
		});
	});
    </script>
</head>
<body class="body">
    <div class="main" id="main">
        <div class="urllogo">
            <img src="/Bys-Website/SourceImageFile/getUrl.jpg"/>
        </div>
        <div class="ashr">
        </div>
        <form method="post">
	        <div class="step">输入用户名</div>
	        <div class="maininfo">
	            <div class="type">用户名</div>
	            <div class="inputtext"><input type="text" id="user" name="username"/></div>
	            <input type="button"  id="GetComfirmCode" size="10" value="确定" class="subbtn"/>
	            <div class="attention">稍后请点击您邮箱里的链接</div>
	        </div>
        </form>
    </div>
    
    <script>
        createMain();
    </script>
    <div class="topbar">
        <div class="logo">
            <img src="/Bys-Website/SourceImageFile/toplogo.jpg"/>
        </div>
        <div class="navi">
            <ul class="naviul">
                <li><a href="/Bys-Website/Public/Video.jsp" class="outli">视频</a></li>
				<li><a href="/Bys-Website/Public/Photo.jsp" class="outli">相册</a></li>
				<li><a href="/Bys-Website/Public/Blog.jsp" class="inli">博客</a></li>
            </ul>
        </div>
        <div class="loginfo">
            <ul class="loginfoul">
				<%if(session.getAttribute("pid")==null){%>
				<li><a href="/Bys-Website/Log_in.jsp">登录</a></li>
				<li><a href="/Bys-Website/Regist.jsp">注册</a></li>
			<%}else{
				 String Sessionid=session.getAttribute("pid").toString();%>
				<li><a href="../PersonMainPage.jsp?userID=<%=Sessionid  %>"><%=session.getAttribute("username").toString()%></a></li>
				<li><a href="../LoginServlet?method=1">退出</a></li>
			<%}%>
			</ul>
        </div>
    </div>
</body>
</html>